<include file="Public:header" />
<div style="boder:1px solid #ccc;margin:10px 10px 0px 10px;">
    <div style="border:1px solid #ccc;height:40px;padding:0 0 0 20px;line-height:40px;">
           本站文件上传管理
    </div>
    <form action="{:U('WebsiteConfigManage/fileUpload')}" method="get">
    <div style="border:1px solid #ccc;height:auto;padding:10px 0px 10px 13px;margin-top:5px;"> 
                    <select name="column_id">
					    <option value="0">请选择栏目</option>
                        <foreach name="columnName" item="val">
                        <option value="{$val.id}" <if condition="$val.id eq $column_id">selected</if> >{$val.column_name}</option>
                        </foreach>
                    </select>
                    <input type="submit" name="config" value="配置" />
    </div>
    </form>
    <if condition="$fileUploadConfig neq null">
    <form action="{:U('WebsiteConfigManage/fileUpload')}" method="post">
        <div style="border:1px solid #ccc;height:auto;padding:10px 11px 10px 11px;margin-top:5px;">
            <table border="0" width="100%">
                 <tr>
                     <input type="hidden" name="id[5]" value="{$fileUploadConfig[5]['id']}" />
                     <td align="right" width="150" style="border:1px solid #ccc">{$fileUploadConfig[5]['config_name']}：</td>
                     <td style="border:1px solid #ccc">
                         &nbsp;<input type="radio" name="config_info[5]" value="1"
    </if>
    <if condition="$fileUploadConfig[5]['config_info'] eq '1'">checked</if> 
    <if condition="$fileUploadConfig neq null">/> 是
    <input type="radio" name="config_info[5]" value="0"
    </if>
    <if condition="$fileUploadConfig[5]['config_info'] eq '0'">checked</if> 
    <if condition="$fileUploadConfig neq null">/> 否(推荐)
                     </td>
                 </tr>
    </if>             
    <if condition="$fileUploadConfig[5]['config_info'] eq '1'">
                 <tr>
                     <input type="hidden" name="id[0]" value="{$fileUploadConfig[0]['id']}" />
                     <td align="right" width="150" style="border:1px solid #ccc">{$fileUploadConfig[0]['config_name']}：</td>
                     <td style="border:1px solid #ccc">
                         &nbsp;<input type="radio" name="config_info[0]" value="1"
    </if>
    <if condition="$fileUploadConfig[0]['config_info'] eq '1' and $fileUploadConfig[5]['config_info'] eq '1'">checked</if>
    <if condition="$fileUploadConfig[5]['config_info'] eq '1'">/> 单文件上传
                        <input type="radio" name="config_info[0]" value="2"
    </if>
    <if condition="$fileUploadConfig[0]['config_info'] eq '2' and $fileUploadConfig[5]['config_info'] eq '1'">checked</if>
    <if condition="$fileUploadConfig[5]['config_info'] eq '1'"> /> 多文件上传
                     </td>
                 </tr>
                 <tr>
                     <input type="hidden" name="id[1]" value="{$fileUploadConfig[1]['id']}" />
                     <td align="right" style="border:1px solid #ccc">{$fileUploadConfig[1]['config_name']}：</td>
                     <td style="border:1px solid #ccc">
                         <input type="text" name="config_info[1]" value="{$fileUploadConfig[1]['config_info']}" /> M <span style="">请输入一个数字，如：<span style="color:red">2</span></span>
                     </td>
                 </tr>
                 <tr>
                     <input type="hidden" name="id[2]" value="{$fileUploadConfig[2]['id']}" />
                     <td align="right" style="border:1px solid #ccc">{$fileUploadConfig[2]['config_name']}：</td>
                     <td style="border:1px solid #ccc">
                         <input type="text" name="config_info[2]" value="{$fileUploadConfig[2]['config_info']}" style="width:60%"/>&nbsp;<span style="">多个文件类型请使用符号“|”隔开！如：<span style="color:red">png|jpg|jpeg</span></span>
                     </td>
                 </tr>
                 <tr>
                     <input type="hidden" name="id[3]" value="{$fileUploadConfig[3]['id']}" />
                     <td align="right" style="border:1px solid #ccc">{$fileUploadConfig[3]['config_name']}：</td>
                     <td style="border:1px solid #ccc">
                         &nbsp;<input type="radio" name="config_info[3]" value="1"
     </if>
     <if condition="$fileUploadConfig[3]['config_info'] eq '1' and $fileUploadConfig[5]['config_info'] eq '1'">checked</if>
     <if condition="$fileUploadConfig[5]['config_info'] eq '1'">/>是
     <input type="radio" name="config_info[3]" value="0" 
     </if>
     <if condition="$fileUploadConfig[3]['config_info'] eq '0' and $fileUploadConfig[5]['config_info'] eq '1'">checked</if>
     <if condition="$fileUploadConfig[5]['config_info'] eq '1'"> />否
                     </td>
                 </tr>
     </if>
     <if condition="$fileUploadConfig[3]['config_info'] eq '1' and $fileUploadConfig[5]['config_info'] eq '1'">
                 <tr>
                     <input type="hidden" name="id[4]" value="{$fileUploadConfig[4]['id']}" />
                     <td align="right" style="border:1px solid #ccc">{$fileUploadConfig[4]['config_name']}：</td>
                     <td style="border:1px solid #ccc">
                         <input type="text" name="config_info[4]" value="{$fileUploadConfig[4]['config_info']}"/> px&nbsp;<span>请按照<span style="color:red">*x*</span>格式填写！*(长)x(为小写字母x)*(宽)，多张使用符号“|”隔开，如<span style="color:red">“30x30|40x50|60x100”</span></span>  
                     </td>
                 </tr>
    </if>
    <if condition="$fileUploadConfig neq null">
             </table>
        </div>
        <div style="border:1px solid #ccc;margin:5px 0px 5px 0px;padding:5px 0px 5px 13px;">
            <input type="hidden" name="column_id" value="{$column_id}" />
            <input type="submit" name="save" value="保存配置" />
            <input type="reset" value="重置" />
        </div>
    </form> 
    </if>
</div>
  </body>
</html>
